<template>
      <div>
          我是演出
          {{$store.state.num}}
          {{$store.state.arr}}
          <button @click="fn">点我</button>
      </div>
</template>

<script>
export default {
     mounted(){
         console.log(this.$store)
         this.$store.dispatch('getList', "1")
     },
     methods:{
         fn(){
             //this.$store.commit调用mutation里的方法
             this.$store.commit('setNum', 1)
         }
     }
}
</script>

<style>

</style>